<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>书籍搜索</title>
    <link rel="icon" type="image/x-icon" href="/images/logo.ico" />
    <link rel="stylesheet" href="/stylesheets/bootstrap.css">
    <link rel="stylesheet" href="/stylesheets/index.css">
</head>
<body>
    <div class="container">
        <%include header%>
    </div>
    <div class="container book_list">
        <div class="wrapper">
            <ul>
            <%if(book&&book.length>0){%>
                <div class="col-xs-12 col-md-12"><h5 class="color">店主为你找到了以下书籍 :</h5></div>
                <%for(var i=0;i<book.length;i++){%>
                    <li class="book_list2">
                    <div class="picBox">
                        <div class="showdiv">
                            <image height='180px' width='180px' src='/images/books/<%=book[i].img%>'></image>
                        </div>
                        <div class="hidediv">
                            <span class="topKuang4">
                                <a href="javascript:void(0)" onclick="shoucang('<%=book[i]._id%>')">收藏</a>
                                <a href="javascript:void(0)" class="add_scar" onclick="join('<%=book[i]._id%>')">加入购物车</a>
                            </span>
                            <span class="bottomSpan text-center">
                                <h4>
                                    <a href="/bookDetil/?id=5ab8e94333a1a107b4f220fd" style="color:#fff" class="text"><%=book[i].name%></a>
                                </h4>
                                <h4 class="text"><%=book[i].author_id.name%></h4>
                                    <h4 class="text">￥<%=book[i].money%></h4>
                            </span>
                        </div>
                    </div>
                    </li>
                <%}%>
            </ul>
        </div>
            <%}else{%>
                <div class="col-xs-12 col-md-12 text-center"><h4 class="color2">没有相关书籍,请换个关键词再试试吧!</h4></div>
                <div class="col-xs-12 col-md-12"><h5 class="color">店主为你推荐以下书籍 :</h5></div>
                <div id="wrapper">
                    <div class="wrapper">
                        <ul>
                            <li class="book_list2">
                                <div class="picBox">
                                    <div class="showdiv"><image height='180px' width='180px' src='/images/books/dygw.jpg'></image></div>
                                    <div class="hidediv">
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ab8e94333a1a107b4f220fd')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ab8e94333a1a107b4f220fd')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4><a href="/bookDetil/?id=5ab8e94333a1a107b4f220fd" style="color:#fff">《解忧杂货店》</a></h4>
                                            <h4>东野圭吾</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                            <li>
                                <div class='picBox'>
                                    <div class='showdiv'>
                                        <image height='180px' width='180px' src='/images/books/dygw.jpg'></image>
                                    </div>
                                    <div class='hidediv'>
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ac0eb7d91d01322f0892824')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ac0eb7d91d01322f0892824')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4>
                                                <a href="/bookDetil/?id=5ac0eb7d91d01322f0892824" style="color:#fff">《放学后》</a>
                                            </h4>
                                            <h4>东野圭吾</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                            <li>
                                <div class='picBox'>
                                    <div class='showdiv'>
                                        <image height='180px' width='180px' src='/images/books/dygw.jpg'></image>
                                    </div>
                                    <div class='hidediv'>
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ac0eb8391d01322f0892825')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ac0eb8391d01322f0892825')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4>
                                                <a href="/bookDetil/?id=5ac0eb8391d01322f0892825" style="color:#fff">《秘密》</a>
                                            </h4>
                                            <h4>东野圭吾</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                            <li>
                                <div class='picBox'>
                                    <div class='showdiv'>
                                        <image height='180px' width='180px' src='/images/books/dygw.jpg'></image>
                                    </div>
                                    <div class='hidediv'>
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ac0eb8891d01322f0892826')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ac0eb8891d01322f0892826')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4>
                                                <a href="/bookDetil/?id=5ac0eb8891d01322f0892826" style="color:#fff">《白夜行》</a>
                                            </h4>
                                            <h4>东野圭吾</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                            <li>
                                <div class='picBox'>
                                    <div class='showdiv'>
                                        <image height='180px' width='180px' src='/images/books/dygw.jpg'></image>
                                    </div>
                                    <div class='hidediv'>
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ac0eb9591d01322f0892827')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ac0eb9591d01322f0892827')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4>
                                                <a href="/bookDetil/?id=5ac0eb9591d01322f0892827" style="color:#fff">《神探伽利略》</a>
                                            </h4>
                                            <h4>东野圭吾</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                            <li>
                                <div class='picBox'>
                                    <div class='showdiv'>
                                        <image height='180px' width='180px' src='/images/books/laoshe.jpg'></image>
                                    </div>
                                    <div class='hidediv'>
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ab8e89e33a1a107b4f220f3')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ab8e89e33a1a107b4f220f3')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4>
                                                <a href="/bookDetil/?id=5ab8e89e33a1a107b4f220f3" style="color:#fff">《骆驼祥子》</a>
                                            </h4>
                                            <h4>老舍</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                            <li>
                                <div class='picBox'>
                                    <div class='showdiv'>
                                        <image height='180px' width='180px' src='/images/books/laoshe.jpg'></image>
                                    </div>
                                    <div class='hidediv'>
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ac0e99991d01322f089280b')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ac0e99991d01322f089280b')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4>
                                                <a href="/bookDetil/?id=5ac0e99991d01322f089280b" style="color:#fff">《四世同堂》</a>
                                            </h4>
                                            <h4>老舍</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                            <li>
                                <div class='picBox'>
                                    <div class='showdiv'>
                                        <image height='180px' width='180px' src='/images/books/laoshe.jpg'></image>
                                    </div>
                                    <div class='hidediv'>
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ac0ea0291d01322f089280e')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ac0ea0291d01322f089280e')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4>
                                                <a href="/bookDetil/?id=5ac0ea0291d01322f089280e" style="color:#fff">《小坡的生日》</a>
                                            </h4>
                                            <h4>老舍</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                            <li>
                                <div class='picBox'>
                                    <div class='showdiv'>
                                        <image height='180px' width='180px' src='/images/books/laoshe.jpg'></image>
                                    </div>
                                    <div class='hidediv'>
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ac0e9a091d01322f089280c')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ac0e9a091d01322f089280c')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4>
                                                <a href="/bookDetil/?id=5ac0e9a091d01322f089280c" style="color:#fff">《茶馆》</a>
                                            </h4>
                                            <h4>老舍</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                            <li>
                                <div class='picBox'>
                                    <div class='showdiv'>
                                        <image height='180px' width='180px' src='/images/books/laoshe.jpg'></image>
                                    </div>
                                    <div class='hidediv'>
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ac0e9ec91d01322f089280d')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ac0e9ec91d01322f089280d')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4>
                                                <a href="/bookDetil/?id=5ac0e9ec91d01322f089280d" style="color:#fff">《猫城记》</a>
                                            </h4>
                                            <h4>老舍</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                            <li>
                                <div class='picBox'>
                                    <div class='showdiv'>
                                        <image height='180px' width='180px' src='/images/books/lyt.jpg'></image>
                                    </div>
                                    <div class='hidediv'>
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ab8e9ce33a1a107b4f22105')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ab8e9ce33a1a107b4f22105')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4>
                                                <a href="/bookDetil/?id=5ab8e9ce33a1a107b4f22105" style="color:#fff">《京华烟云》</a>
                                            </h4>
                                            <h4>林语堂</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                            <li>
                                <div class='picBox'>
                                    <div class='showdiv'>
                                        <image height='180px' width='180px' src='/images/books/lyt.jpg'></image>
                                    </div>
                                    <div class='hidediv'>
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ac0ec8e91d01322f0892836')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ac0ec8e91d01322f0892836')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4>
                                                <a href="/bookDetil/?id=5ac0ec8e91d01322f0892836" style="color:#fff">《啼笑皆非》</a>
                                            </h4>
                                            <h4>林语堂</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                            <li>
                                <div class='picBox'>
                                    <div class='showdiv'>
                                        <image height='180px' width='180px' src='/images/books/lyt.jpg'></image>
                                    </div>
                                    <div class='hidediv'>
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ac0ec6391d01322f0892833')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ac0ec6391d01322f0892833')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4>
                                                <a href="/bookDetil/?id=5ac0ec6391d01322f0892833" style="color:#fff">《吾国与吾民》</a>
                                            </h4>
                                            <h4>林语堂</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                            <li>
                                <div class='picBox'>
                                    <div class='showdiv'>
                                        <image height='180px' width='180px' src='/images/books/lyt.jpg'></image>
                                    </div>
                                    <div class='hidediv'>
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ac0ec6f91d01322f0892835')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ac0ec6f91d01322f0892835')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4>
                                                <a href="/bookDetil/?id=5ac0ec6f91d01322f0892835" style="color:#fff">《老子的智慧》</a>
                                            </h4>
                                            <h4>林语堂</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                            <li>
                                <div class='picBox'>
                                    <div class='showdiv'>
                                        <image height='180px' width='180px' src='/images/books/lyt.jpg'></image>
                                    </div>
                                    <div class='hidediv'>
                                        <span class="topKuang4">
                                            <a href="javascript:void(0)" onclick="shoucang('5ac0ec6991d01322f0892834')">收藏</a>
                                            <a href="javascript:void(0)" class="add_scar" onclick="join('5ac0ec6991d01322f0892834')">加入购物车</a>
                                        </span>
                                        <span class="bottomSpan text-center">
                                            <h4>
                                                <a href="/bookDetil/?id=5ac0ec6991d01322f0892834" style="color:#fff">《生活的艺术》</a>
                                            </h4>
                                            <h4>林语堂</h4>
                                        </span>
                                    </div>
                                </div>
                            </li>
                        </ul>
                    </div>
                </div>
            <%}%>
    </div>              
</body>
<script>
    window.onload=function(){
        if('<%=key%>'){
            $('.text').GL({
                ocolor: '#f55245',
                oshuru: '<%=key%>'
            });
            $('#searchKey').attr('value', '<%=key%>')
        }
    }
</script>
<script src="/javascripts/jquery-3.2.1.min.js"></script>
<script src="/javascripts/bootstrap.js"></script>
<script src="/javascripts/jquery.fly.min.js"></script>
<script src="/javascripts/layer/layer.js"></script>
<script src="/javascripts/public.js"></script>
<script src="/javascripts/tuijian.js"></script>
</script>
</html>